/* Layout */
const Layout = resolve => require(['@/views/layout/Layout'], resolve);

const PermissionRouterMap = {
  id: 1,
  path: '/permissions',
  component: Layout,
  redirect: '/permissions/users',
  name: '权限管理',
  meta: {title: '权限管理', icon: 'jurisdiction', power: 'permissions'},
  showMode: 'DEFAULT',
  children: [
    {
      id: 10,
      path: 'users',
      name: '系统用户',
      component: resolve => require(['@/views/permissions/users'], resolve),
      meta: {title: '系统用户', icon: 'user', power: 'permissions.users'},
      children: [
        {
          path: 'modifyUser',
          name: '新增 / 编辑',
          component: resolve => require(['@/views/permissions/users/modifyUser'], resolve),
          meta: {title: '新增 / 编辑', power: 'permissions.users.modifyUser'},
          hidden: true
        }, {
          path: 'userInfo',
          name: '用户详情',
          component: resolve => require(['@/views/permissions/users/info'], resolve),
          meta: {title: '用户详情', power: 'permissions.users.info'},
          hidden: true
        }
      ]
    }, {
      id: 21,
      path: 'departments',
      name: '团队列表',
      component: resolve => require(['@/views/permissions/departments'], resolve),
      meta: {title: '团队列表', icon: 'team', power: 'permissions.departments'}
    }, {
      id: 6,
      path: 'roles',
      name: '角色列表',
      component: resolve => require(['@/views/permissions/roles'], resolve),
      meta: {title: '角色列表', icon: 'role', power: 'permissions.roles'},
      children: [
        {
          path: 'modifyRole',
          name: '添加 / 编辑',
          component: resolve => require(['@/views/permissions/roles/modifyRole'], resolve),
          meta: {title: '添加 / 编辑', power: 'permissions.roles.modifyRole'},
          hidden: true
        }
      ]
    }
  ]
}

export default PermissionRouterMap;
